﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Data;
using System.Data.SqlClient;
using System.Web.UI.WebControls;

namespace TestJQGrid
{
    public class SlabControl
    {
        #region members - private
        private MatrixMaster matrix;
        #endregion

        #region create slab
        public SlabControl(int SlabId)
        {
            matrix = new MatrixMaster(SlabId);
        }

        public SlabControl(int SlabId, int rows, int columns)
        {
            matrix = new MatrixMaster(SlabId, rows, columns);
        }
        #endregion

        #region getters
        public MatrixMaster getMatrix() { return matrix; }
        #endregion

        #region update2db
        public void update(TextBox[,] tb) { matrix.updateMatrix(tb); matrix.updateDB(); }
        public void update(DataTable dt) { matrix.updateMatrix(dt); matrix.updateDB(); }
        #endregion

    }
}